﻿using System;
using System.Data;
using System.Web;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using AnyOffice.Components;
using AnyOffice.DAL;
using AnyOffice.Model;
namespace AnyOffice.general.system.chatroom
{
    public partial class _new : ModulePage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (this.Page.IsPostBack)
            {
                ChatSessionsDao dao = new ChatSessionsDao();
                ChatSessionsData data = new ChatSessionsData();
                data.SessionName = this.txtSessionName.Value;
                dao.Insert(base.Conn, data);
                base.CloseConn();
                Response.Redirect("index.aspx");
            }
        } 

    }
}
